type LangType =
    | 'json'
    | 'java'
    | 'python'
    | 'SQL'
    | 'html'
    | 'css'
    | 'xml'
    | 'css'
    | 'csharp'
    | 'javascript'
    | 'markdown'
    | 'yaml'

interface UIHelpers {
    isOpen: boolean
    toggle: () => void
    close: () => void
    open: () => void
}

export interface CodeType {
    rawText: string
    lang?: LangType | string
    containerDivClass?: string
    codeDivClass?: string
    uihelpers?: UIHelpers
}

// 使用 TypeScript 接口规范类型,支持语言配置 ---------------------------------------------------
export interface LangConfig {
    name: string
    formatter: (text: string) => string
    prism: () => Promise<unknown>
}
